package es.unileon.prg2.patterns.composite;

import es.unileon.prg2.patterns.handler.GenericId;
import es.unileon.prg2.patterns.handler.Handler;

public class Town extends Composite{
	
	private Handler id;
	final int level = 4;
	
	public Town(Handler id){
		this.id = id;
	}
	
	public Town(String id){
		this(new GenericId(id));
	}
	
	public Handler getId(){
		return this.id;
	}
	
	@Override
	public int getLevel() {
		return this.level;
	}
	
	public String toString(){
		return "\t\t\t\tTown: " + this.id.toString() + "\n";
	}
}
